import { axios } from '@/utils/request'
export function getParkPage(parameter) {
  parameter.pageNum = parameter.current;
  parameter.pageSize = parameter.size;
  return axios({
    url: '/sys/hr/admin/park/pageQueryPark',
    method: 'get',
    params:parameter
  })
}
export function addPark(parameter) {
  return axios({
    url: '/sys/hr/admin/park/add',
    method: 'post',
    data:parameter
  })
}
export function updatePark(parameter) {
  return axios({
    url: '/sys/hr/admin/park/update',
    method: 'post',
    data:parameter
  })
}
export function disOrEnablePark(parameter) {
  return axios({
    url: '/sys/hr/admin/park/disOrEnablePark',
    method: 'post',
    data:parameter
  })
}
// 政策库配置
export function listHrPolicyType() {
  return axios({
    url: '/sys/hr/policy/listHrPolicyType',
    method: 'get'
  })
}
export function pagePolicy(parameter) {
  return axios({
    url: '/sys/hr/policy/pagePolicy',
    method: 'post',
    data:parameter
  })
}
export function policyQuery(id) {
  return axios({
    url: `/sys/hr/policy/query/${id}`,
    method: 'get'
  })
}
export function policyAdd(parameter) {
  return axios({
    url: '/sys/hr/policy/add',
    method: 'post',
    data:parameter
  })
}
export function policyUpdate(parameter) {
  return axios({
    url: '/sys/hr/policy/update',
    method: 'post',
    data:parameter
  })
}
export function policyDelete(parameter) {
  return axios({
    url: '/sys/hr/policy/delete',
    method: 'post',
    data:parameter
  })
}
// 社保比例查询

// 社保比例配置
export function pageCity(parameter) {
  return axios({
    url: '/sys/hr/insureTool/city/pageCity',
    method: 'post',
    data:parameter
  })
}
export function cityAll() {
  return axios({
    url: '/sys/hr/insureTool/city/all',
    method: 'get'
  })
}
export function cityAdd(parameter) {
  return axios({
    url: '/sys/hr/insureTool/city/add',
    method: 'post',
    data:parameter
  })
}
export function cityDelete(id) {
  return axios({
    url: `/sys/hr/insureTool/city/delete/${id}`,
    method: 'get'
  })
}
export function typeGetTypes(id) {
  return axios({
    url: `/sys/hr/insureTool/type/getTypes/${id}`,
    method: 'get'
  })
}
export function typeAdd(parameter) {
  return axios({
    url: '/sys/hr/insureTool/type/add',
    method: 'post',
    data:parameter
  })
}
export function typeDelete(id) {
  return axios({
    url: `/sys/hr/insureTool/type/delete/${id}`,
    method: 'get'
  })
}
export function configQuery(parameter) {
  return axios({
    url: `/sys/hr/insureTool/config/queryConfig`,
    method: 'post',
    data:parameter
  })
}
export function configAdd(parameter) {
  return axios({
    url: '/sys/hr/insureTool/config/add',
    method: 'post',
    data:parameter
  })
}

// 社保计算器
export function getTypesWithBase(id) {
  return axios({
    url: `/sys/hr/insureTool/type/getTypesWithBase/${id}`,
    method: 'get'
  })
}
export function configCalculator(parameter) {
  return axios({
    url: '/sys/hr/insureTool/config/calculator',
    method: 'post',
    data:parameter
  })
}